package com.qs.services;

import java.util.List;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import com.qs.dao.ChannelDAO;
import com.qs.entities.Channel;
import com.qs.exceptions.ServiceException;

public class ChannelService {
	
	protected final Logger log = LoggerFactory.getLogger(ChannelService.class);
	
	private ChannelDAO channelDao;
	
	public List<Channel> getAllChannels()throws ServiceException {
		try{
			return channelDao.findAll();
		}
		catch(Exception exc){
			throw new ServiceException(exc.getMessage(),exc);
		}
	}

	public ChannelDAO getChannelDao() {
		return channelDao;
	}

	public void setChannelDao(ChannelDAO channelDao) {
		this.channelDao = channelDao;
	}
	
	
	
	
}
